Target-based smb and dce/rpc processing for an intrusion detection system or instrusion prevention system

ABSTRACT

A method performed in a processor of an intrusion detection/prevention system (IDS/IPS) checks for valid packets in an SMB named pipe in a communication network. In a processor configured as an IDS/IPS, a packet in a transmission is received and a kind of application of a target of the packet is determined. Also, the data in the packet is inspected by the IDS/IPS as part of the SMB named pipe on only one of a condition that: (a) the FID in an SMB command header of the packet is valid (i) for segments/fragments in the SMB named pipe and (ii) for the determined kind of application of the target of the packet, as indicated by a reassembly table, and (b) the determined kind of application of the target of the packet does not check the FID, as indicated by the reassembly table.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application claims the benefit of the following Provisional applications: 61/103,630 filed Oct. 8, 2008, all of which is expressly incorporated herein by reference.

TECHNICAL FIELD

The present invention relates in general to network traffic analysis, and more specifically to analyzing server message block (SMB) command packets in a SMB named pipe, and analyzing distributed computing environment/remote procedure call (DCE/RPC) request fragments in a DCE/RPC request, optionally in connection with intrusion detection/prevention.

BACKGROUND

An SMB command, which is utilized in packet network communications, can be separated into multiple packets that are sent to the target destination, as part of the same SMB named pipe. The multiple packets can be reassembled by the destination to re-create the original SMB command.

Also, a DCE/RPC request utilized in packet network communications can be separated into request fragments which are sent to the destination, as part of the same DCE/RPC request. Each request fragment still belongs to the original DCE/RPC, and can be reassembled by the destination to re-create the original DCE/RPC request.

The inventor has noted that different kinds of operating systems and/or applications have unique methods of SMB packet reassembly and DCE/RPC fragment reassembly. For example, different WINDOWS™ and SAMBA™ versions handle SMB and DCE/RPC processing differently. These methods of reassembling DCE/RPC request fragments and/or SMB command packets can be exploited by attackers.

The conventional IDS/IPS is not sensitive to these differences, and may reassemble the SMB packets, SMB transaction fragments/segments and/or DCE/RPC request fragments differently than the target destination host. The reassembled SMB command or DCE/RPC request analyzed by the IDS/IPS may be different from the SMB command or DCE/RPC request reassembled by the SMB or DCE/RPC processing at the target destination host. Consequently, an attack that successfully exploits these differences in reassembly can cause the IDS/IPS to miss the malicious traffic. An attacker may use such an evasion to exploit a vulnerability and go unnoticed.

SUMMARY

Accordingly, one or more embodiments of the present invention provide methods, systems, and computer readable memory mediums, in a processor of an intrusion detection/prevention system (IDS/IPS), for checking for valid packets in an SMB named pipe in a communication network. An embodiment includes receiving, in a processor configured as an IDS/IPS, a packet in a transmission and determining a kind of application of a target of the packet in response to receiving the packet. Also provided is including, in the IDS/IPS, the data in the packet as part of the SMB named pipe data inspected by the IDS/IPS as part of the SMB named pipe on only one of a condition that: (a) the FID in an SMB command header of the packet is valid (i) for segments/fragments in the SMB named pipe and (ii) for the determined kind of application of the target of the packet, as indicated by a reassembly table, and (b) the determined kind of application of the target of the packet does not check the FID, as indicated by the reassembly table.

Another embodiment provides methods, systems and computer readable memory mediums, in a processor of an intrusion detection/prevention system (IDS/IPS), for checking for valid packets in an SMB named pipe in a communication network. The embodiment can include receiving, in a processor configured as an IDS/IPS, a fragment/segment, and determining a kind of application of a target of the fragment/segment in response to receiving the fragment/segment. The embodiment also can include separating, in the IDS/IPS, fragments/segments with a same multiplex ID (MID) as part of a same SMB transaction command from fragments/segments with a different MID, the MID being in the SMB frame header, all for fragments/segments in the same SMB named pipe, when a reassembly table indicates that the kind of application of the target separates based on MID. Also, the embodiment can include processing, in the IDS/IPS, the same SMB transaction command with the same MID as being in a separate SMB transaction command instead of with the fragments/segments with the different MID when the kind of application of the target separates based on MID.

Still another embodiment provides methods, systems and computer readable memory mediums, in a processor of an intrusion detection/prevention system (IDS/IPS), for reassembling distributed computing environment/remote procedure call (DCE/RPC) request fragments. The embodiments can include receiving, in a processor configured as an IDS/IPS, plural request fragments belonging to a single DCE/RPC request. Also, the embodiment can include determining, in the IDS/IPS, the kind of application of a target of the DCE/RPC request. Furthermore, the embodiment can include selecting, in the IDS/IPS, one of the request fragments as a source of a context ID depending on the target kind of application as indicated in a reassembly table. Also, the embodiment can include reassembling, in the IDS/IPS, the plural request fragments into a reassembled request. Further, the embodiment can include inserting, in the IDS/IPS, the context ID from the selected request fragment into the context ID of a DCE/RPC header of the reassembled request.

Yet another embodiment provides methods, systems and computer readable memory mediums, in a processor of an intrusion detection/prevention system (IDS/IPS), for reassembling request fragments. The embodiment can include receiving, in a processor configured as an IDS/IPS, plural request fragments belonging to a single request. Also included is determining, in the IDS/IPS, the kind of application of a target of the request. Also included is selecting, in the IDS/IPS, one of the request fragments as a source of an operation number as indicated in a reassembly table depending on the target kind of application. Further included is reassembling, in the IDS/IPS, the plural request fragments into a reassembled request. Also provided is inserting, in the IDS/IPS, the operation number from a DCE/RPC header of the selected request fragment into the operation number of a DCE/RPC header of the reassembled request.

Further, the purpose of the foregoing abstract is to enable the U.S. Patent and Trademark Office and the public generally, and especially the scientists, engineers and practitioners in the art who are not familiar with patent or legal terms or phraseology, to determine quickly from a cursory inspection the nature and essence of the technical disclosure of the application. The abstract is neither intended to define the invention of the application, which is measured by the claims, nor is it intended to be limiting as to the scope of the invention in any way.

BRIEF DESCRIPTION OF THE DRAWINGS

The accompanying figures, where like reference numerals refer to identical or functionally similar elements and which together with the detailed description below are incorporated in and form part of the specification, serve to further illustrate various exemplary embodiments and to explain various principles and advantages in accordance with the present invention.

FIG. 1 is a diagram illustrating a simplified and representative environment associated with segment analysis;

FIG. 2 is a diagram illustrating a prior art SMB named pipe processing;

FIG. 3 is a diagram illustrating target-based SMB processing according to a first embodiment;

FIG. 4 is a diagram illustrating another prior art SMB transaction command processing;

FIG. 5 is a diagram illustrating target-based SMB processing according to a second embodiment;

FIG. 6 is a diagram illustrating a prior art DCE/RPC processing;

FIG. 7 is a diagram illustrating target-based DCE/RPC processing according to a third and fourth embodiment;

FIG. 8 is a block diagram illustrating portions of an exemplary computer system;

FIG. 9 is a block diagram illustrating portions of an SMB frame header and an SMB command header;

FIG. 10 is a block diagram illustrating portions of a DCE/RPC request header;

FIG. 11 is a flow chart illustrating a process to check for valid packets in an SMB named pipe according to the first embodiment;

FIG. 12 is a flow chart illustrating a process to check for valid packets in an SMB named pipe according to the second embodiment; and

FIG. 13 is a flow chart illustrating a process to reassemble DCE/RPC request fragments according to the third and fourth embodiments.

DETAILED DESCRIPTION

In overview, the present disclosure concerns analysis of network traffic on communication networks, often referred to as packet switching networks, which support communication from wireless and/or wire line devices to a destination. Such communication networks may carry SMB commands which have been split at the SMB level into plural packets, and/or DCE/RPC requests which have been split at the DCE/RPC level into variable sized transmission control protocol (TCP) segments. More particularly, various inventive concepts and principles are embodied in systems, devices, and methods therein for analyzing segments, optionally in connection with intrusion detection/prevention systems.

The instant disclosure is provided to further explain in an enabling fashion the best modes of performing one or more embodiments of the present invention. The disclosure is further offered to enhance an understanding and appreciation for the inventive principles and advantages thereof, rather than to limit in any manner the invention. The invention is defined solely by the appended claims including any amendments made during the pendency of this application and all equivalents of those claims as issued.

Relational terms such as first and second, and the like, if any, are used herein solely to distinguish one from another entity, item, or action without necessarily requiring or implying any actual such relationship or order between such entities, items or actions. Some embodiments may include a plurality of processes or steps, which can be performed in any order, unless expressly and necessarily limited to a particular order; i.e., processes or steps that are not so limited may be performed in any order.

Much of the inventive functionality and many of the inventive principles when implemented, are best supported with or in software or integrated circuits (ICs), such as a digital signal processor and software therefore, and/or application specific ICs. It is expected that one of ordinary skill, notwithstanding possibly significant effort and many design choices motivated by, for example, available time, current technology, and economic considerations, when guided by the concepts and principles disclosed herein will be readily capable of generating such software instructions or ICs with minimal experimentation. Therefore, in the interest of brevity and minimization of any risk of obscuring the principles and concepts according to the present invention, further discussion of such software and ICs, if any, will be limited to the essentials with respect to the principles and concepts used by the exemplary embodiments.

Consider the series of steps in the following example in connection with named pipes:

Login/Authenticate returns UID. Connect to IPC$ share—returns TID—needs a valid UID Open named pipe—returns FID—needs a valid UID and TID that opened IPC$ share

Login

Connect to IPC$ share Open named pipe—say \srvsvc—FID1 Open named pipe—say \spoolss—FID2

Write to FID1 Write to FID2 Write to FID1 Write to FID2 Write to FID1 Write to FID2

Read from FID1—gets results of data/request sent Read from FID2—gets results of data/request sent

On a very basic level, the IDS/IPS needs to be aware of the different named pipes being written to so that the IDS/IPS does not munge all of the data together. Say an attacker is using FID1 to send an exploit and say the exploit spans two writes:

Write to FID1---|

Write to FID2--->exploit

Write to FID1---| Write to FID2 Write to FID1 Write to FID2

If the IDS does not separate the data going to each of the named pipes it will likely miss the exploit. It should be separating the data like so:

Write to FID1 Write to FID2 Write to FID1 Write to FID2 Write to FID1 Write to FID2

The UID/TID/FID relationship needs to be understood on a per target basis so an attacker can't slip in invalid data between writes to obscure an attack. Say for the Windows XP case:

Login—UID1 Login—UID2

Connect to IPC$ share using UID1-TID1 Open named pipe using UID1/TID1-FID1 Write to FID1 using UID1/TID1/FID1---| Write to FID1 using UID2/TID1/FID1--->exploit Write to FID1 using UID1/TID1/FID1---|

The server will not accept the second write, so the IDS should not include the data in the second write for desegmentation/defragmentation and evaluation.

Now, consider the series of steps in the following example in connection with an SMB transaction:

Login—UID1

Connect to IPC$ share using UID1-TID1 Open named pipe using UID1/TID1-FID1

Transact—UID1/TID1/FID1 MID1/PID1 Transact—UID1/TID1/FID1 MID2/PID2 Transact Sec—MID1/PID1---|

Transact Sec—MID2/PID2---->exploit

Transact Sec—MID1/PID1 Transact Sec—MID2/PID2 Transact Sec—MID1/PID1 Transact Sec—MID2/PID2

The server will collect these segments until the total data for each SMB transaction is sent and then send to the named pipe. The data should be separated like this:

Transact—UID1/TID1/FID1 MID1/PID1 Transact Sec—MID1/PID1 Transact Sec—MID1/PID1 Transact Sec—MID1/PID1 Transact—UID1/TID1/FID1 MID2/PID2 Transact Sec—MID2/PID2 Transact Sec—MID2/PID2 Transact Sec—MID2/PID2

These and other problems in SMB and DCE/RPC processing can be addressed by various embodiments.

Further in accordance with exemplary embodiments, target-based SMB and/or DCE/RPC processing can provide an IDS/IPS the ability to maintain the same state and to reassemble both segmented SMB requests and/or fragmented DCE/RPC requests as does the target destination host. This can preclude evasion attacks since both the IDS/IPS and the destination host are in the same state and reassemble SMB segments and/or DCE/RPC fragments identically.

Referring now to FIG. 1, a diagram illustrating a simplified and representative environment associated with segment analysis will be discussed and described. In the illustration, an intruder 101 (such as a computer system) transmits a transmission to a destination 109. In this example, the transmission is transmitted via a network 103, a router 105, and a firewall 107 to the destination 109. The communications to the destination 109 can be monitored in accordance with well known techniques by an intrusion detection/prevention system 111, such as with a sensor. Although this illustration provides a sensor behind the firewall 107, the sensor can be provided anywhere before the destination 109. Alternatively, the intrusion detection/prevention system 111 can be provided in-line with the destination 109, or can be incorporated into the destination 109.

An SMB command in a transmission can be segmented at the SMB layer into packets or segments (sometimes referred to herein as fragments or fragments/segments) in accordance with known techniques. Also, a DCE/RPC request can be fragment at the DCE/RPC layer into DCE/RPC request fragments. The packets and segments are sent to the destination 109, and the destination 109 reassembles the packets and fragments into the SMB command or DCE/RPC request, as appropriate. The order in which the destination 109 reassembles packets and fragments is a by-product of the SMB layer processing or DCE/RPC layer processing, alone or in combination with the particular operating system on the destination 109. The method in which packets or fragments are reassembled by an application in combination with a particular operating system can be exploited by the intruder 101. Note that although this illustration assumes an intruder 101 sending transmissions or fragments, transmission or fragments that are analyzed can be sent from anywhere.

The illustrated IDS/IPS 111 includes portions for managing 113 packet reconstruction to handle SMB named pipe instance, managing 115 packet reconstruction to handle transaction tracking, reassembling 117 DCE/RPC fragments with context ID sensitivity, and reassembling 119 DCE/RPC fragments with operation number sensitivity (respectively, first, second, third and fourth embodiments). The IDS/IPS can include a combination of one, two, three, or four of the portions 113, 115, 117, 119. Conveniently, the portions 113, 115, 117, 119 can be provided as a preprocessor to the IDS/IPS, that is, to process data before it is evaluated for intrusion.

A first embodiment for processing SMB commands is discussed in connection with FIG. 2 (prior art), FIG. 3, and FIG. 11. A second embodiment for processing SMB commands is discussed in connection with FIG. 4 (prior art), FIG. 5, and FIG. 12. A third embodiment and fourth embodiment for processing DCE/RPC requests are discussed in connection with FIG. 6 (prior art), FIG. 7, and FIG. 13. Each of these embodiments is discussed in detail below.

First Embodiment

In accordance with known techniques for an SMB named pipe, a user logs in (is assigned a unique UID), opens a share (is assigned a tree id (TID)), and opens an SMB named pipe (is assigned a file id (FID)). Each of the UID, TID, and FID is unique. The standard SMB header has fields for UID and TID and FID.

Different operating systems and their SMB applications (hereafter, an “OS/application combination”) have different requirements for how to open an SMB named pipe for each of these within an SMB session.

In some OS/application combinations, it does not matter what UID or TID or FID is used—in other combinations, the FID matters, and perhaps the UID and/or TID matter. In some OS/application combinations, when a file is opened, it matters whether particular UIDs and TIDs are used when that FID is opened—others, not. It is ultimately the SMB layer on the target of the SMB request that handles the SMB request. For Windows, because Windows is closed source i_(t) unknown whether it is the kernel or a separate application that handles the SMB layer, such as a service host. In LINUX or UNIX, Samba is in an application layer. The present inventor noticed that different applications respond differently to the same UID, TID and FID in an SMB request.

An IDS/IPS traditional includes a preprocessor which formats the data before being evaluated for intrusions, among other things. One of the main purposes of the preprocessor is to do defragmentation, including deciding which named pipe instance a fragment belongs to.

With SAMBA 3.0.22 (as an example), the SMB request only needs the FID (without regard to UID and TID) to always get the same pipe instance.

So, as packets are coming in, one needs to know which named pipe the packet is going to be handled as in the target system in order to properly reassemble and evaluate fragments and packets for different kinds of OS/application combinations. (Both fragments or segments are split into fragmented or segmented packets at the application layer (unlike handling of IP fragments and TCP segments).

The key: as a target system is connected up, some combination of the UID, TID and/or FID may have to be specified, or not, depending on the OS/application combination at the target. It can be important to be able to identify whether or not a particular access is valid, as connections and transactions are tracked that go across that named pipe.

Referring now to FIG. 2, a diagram illustrating a prior art SMB named pipe processing will be discussed and described. This illustrates an evasion example: someone sends a FRAG1 (valid packet 203, which contains first half of exploit), FRAG2 (invalid packet 205 due to incorrect FID which will be ignored by the application on predetermined kinds of OS/application combinations of the target 211), and FRAG3 (valid packet 207, which contains second half of exploit). Each of these is on the same named pipe 201. Without this invention, the IDS/IPS sees all three fragments/packets 219, 221, 223 on a named pipe 225, whereas the target operating system sees only FRAG1 and FRAG3, which have the first half of exploit 213 and second half of exploit 215, together creating an exploit 217. The IDS then misses the attack or falsely alerts since the exploit spans FRAG1 and FRAG3, in this example with an intervening packet 205.

A first embodiment can improve the handling of SMB. A lookup table for SMB named pipe reassembly can be included in the IDS/IPS or its preprocessor, for the combination of OS/application targeted by the SMB request. The OS/Application combination (e.g., Windows 2003) can be looked up and returned by known technology. The lookup table can contain indications of how to process FID, and/or FUD/UID/TID, and even whether or not to check the FID/UIS/TID for each of predetermined OS/application combinations. The IDS/IPS or its preprocessor accordingly can flexibly and accurately handle SMB commands targeted to different OS/application combinations.

The SMB packet is received, and based on its IP address the OS/application (e.g., WINDOWS VISTA) is returned, and then the table is referenced for checking the FID, and/or FID/UID/TID based on the IP address. The named-pipe processing makes sure that the FID (in the appropriate context of the UID and TID, i.e., if required by the OS/application that is processing the SMB request) is valid for the segments/fragments. The lookup table can be set up which stores the UID and TID used to open the FID. Thus, after the pipe is open, checking can be done as to whether the FID is valid, given the UID and TID, further depending on the application on the target that is processing the SMB request.

As a concrete example, for UID, the system can check whether there was a valid login. Also, the system can check whether UID and TID in the request previously were used to open the named pipe, for example, Windows Vista. There are different requirements depending on the OS/application combination at the target as to whether or not the request is valid.

Referring now to FIG. 3, a diagram illustrating target-based SMB processing according to a first embodiment will be discussed and described. FIG. 3 can be compared to FIG. 2 (prior art) to appreciate the more effective result. FIG. 3 illustrates a failed evasion example: a valid packet 303 contains first half of exploit, a packet 305 which is invalid due to incorrect FID, and a valid packet 307 contains second half of exploit. Each of these is on the same named pipe 301. The IDS/IPS 309 determines the kind of application of the target of the packet, and determines whether the application has special handling for packets with FID, UID, and/or TID and what that handling is, for example by referring to the SMB named pipe reassembly table 310. In the present example, the named pipe reassembly table for the present target system indicates that FID is checked, and a fragment with incorrect FID is not included as part of the data for the named pipe. (For other target systems, the named pipe reassembly table indicates that packets with an invalid FID are not ignored, or that packets with an invalid UID and/or TID are not included as part of the data for the named pipe. The information in the table is predetermined to match SMB handling of different kinds of applications.) The valid packets 303, 307 are included as data in the SMB named pipe 323. Since the invalid packet 305 is not included as part of the data for the SMB named pipe, the IDS/IPS evaluates the two fragments 319, 321 as data in the SMB named pipe 323. In this example, both the IDS/IPS and the target see only the two valid packets 319, 321, 313, 315, which have the first half of exploit and second half of exploit, together creating an exploit. The IDS then accurately notes the exploit that spans the first and third packets 303, 307.

Second Embodiment

The second embodiment further considers the effect of the PID (process ID) and/or MID (multiplex ID) on the reassembly of SMB fragments/segments into SMB transaction commands by the IDS/IPS prior to the evaluation of the transaction commands by the IDS/IPS.

The transaction command, such as an SMB command, writes data to the named pipe. The MID and PID fields are important if the transaction is segmented. The application at the target needs to keep track of the secondary transaction commands' MID and PID to make sure the segment is being put into the right place.

A transaction SMB command causes the data to be written to the named pipe only when all of the segments are received by the target. An attacker can interleave an exploit with the secondary transaction commands. Segments for different transaction commands can be interleaved. The MID and PID fields indicate which transaction the segments belong to. In a typical transaction, none of the data is written to the pipe until all of the segments are gotten by the server. If two transactions are going at the same time, the IDS/IPS can more accurately identify intrusion events if it knows which transaction the segments belong to.

At the source end of the named pipe is the DCE/RPC processor.

Referring now to FIG. 4, a diagram illustrating another prior art SMB transaction command processing will be discussed and described. This illustrates an evasion example: FRAGA 403 (main SMB transaction, with same MID and PID, which contains first half of exploit), FRAGB 405 (secondary SMB transaction, with an MID different from FRAGA 403 but the same PID in the SMB frame header), FRAGC 407 (secondary SMB transaction, with the same MID as FRAGA 403 but a different PID in the SMB frame header), and FRAGD 409 (secondary SMB transaction with the same MID and PID as FRAGA 403, which contains the second half of the exploit). Each of these is on the same named pipe 411. The conventional IDS/IPS 413 sees the data in all four fragments/packets 423, 425, 427, 429 as belong to one or more transaction commands 431, whereas the target operating system sees only FRAGA and FRAGD, which contain the first half of exploit 417 and second half of exploit 419, together creating an SMB transaction command 421 with an exploit. The conventional IDS/IPS then misses the attack or falsely alerts since the exploit spans FRAGA and FRAGD in this example, with intervening packets 405, 407.

A second embodiment can improve the handling of SMB. A lookup table for SMB transaction reassembly can be included in the IDS/IPS or its preprocessor, for the combination of OS/application targeted by the SMB request. The OS/Application combination (e.g., Windows 2003) which is on the target can be looked up and returned by known technology. The lookup table can contain predetermined indications of how to separate fragments/segments in the same SMB named pipe and collect them into SMB transaction commands, based on the MID and/or PID, for each of predetermined OS/application combinations. The IDS/IPS or its preprocessor accordingly can flexibly and accurately evaluate SMB transactions which are targeted to different OS/application combinations.

The SMB fragment/segment is received, and based on its IP address the OS/application (e.g., WINDOWS VISTA) is returned, and then the table is referenced for checking the MID and/or PID based on the OS/application of the target. The table can indicate whether the kind of OS/application separates fragments/segments with a different MID and/or PID into different SMB transaction commands.

Referring now to FIG. 5, a diagram illustrating target-based SMB processing according to a second embodiment will be discussed and described. In FIG. 5, the data in the SMB transaction command are reassembled for evaluation by the IDS/IPS just as it is assembled by the target. Furthermore, by referencing the SMB transaction reassembly table 514 to determine whether to sort the fragments by MID, and whether to further sort the fragments by PID, the single IDS/IPS 513 can accurately evaluate SMB transactions transmitted to different kinds of OS/application combinations which reassemble the data in the fragments differently from each other.

Compare FIG. 4 to FIG. 5, with the same evasion example: FRAGA 503 (main SMB transaction, with same MID and PID, which contains first half of exploit), FRAGB 505 (secondary SMB transaction, with an MID different from FRAGA 503 but the same PID in the SMB frame header), FRAGC 507 (secondary SMB transaction, with the same MID as FRAGA 503 but a different PID in the SMB frame header), and FRAGD 509 (secondary SMB transaction with the same MID and PID as FRAGA 503, which contains the second half of the exploit). Each of these is on the same named pipe 511. In FIG. 5, the IDS/IPS 513 determines the kind of application of the target of the packet, and determines whether the kind of application has special handling for packets in the same SMB named pipe with MID and/or PID and what that handling is, for example by referring to the SMB transaction reassembly table 514. In the present example, the SMB transaction reassembly table 514 for the present target system indicates that fragments/segments are processed in the same SMB transaction command when they have the same MID and same PID. (For other target systems, the SMB transaction reassembly table can indicate that the MID and PID are not used for grouping fragments/segments into a single SMB transaction command, or that the MID (but not PID) is used for grouping.) FRAGA 523 and FRAGD 525 have the same MID and PID, and therefore the IDS/IPS 513 using the SMB transaction reassembly table 514 considers them to belong to a single SMB transaction command 527. FRAGB 529 and FRAGC 533 are included as data in the SMB transaction command 527. Since the fragment/segments with either a different MID or different PID are not included as part of the SMB transaction command 527 analyzed by the IDS/IPS 513, both the IDS/IPS and the target see the same SMB transaction command 527, 521, which has the first half of exploit and second half of exploit, together creating an exploit. The IPS/IDS 513 then accurately notes the exploit that spans FRAGA 503 and FRAGD 509.

Third Embodiment

The third embodiment further considers the effect of the context ID on the reassembly of DCE/RPC request fragments into DCE/RPC requests by the IDS/IPS prior to the evaluation of the DCE/RPC requests by the IDS/IPS.

Every DCE/RPC request has a context ID in the DCE/RPC header which is a handle that refers to the interface to which the request is made. If the request is fragmented, each fragment has only a part of the request; each fragment also has a context ID. The fragments are put back together to reassemble the DCE/RPC request. Although the fragments each include a context ID, only one of the fragments needs to have the context ID for the target application to put the fragments back together into the reconstituted request. However, the fragment that the target application selects from which to obtain the context ID is dependent on the target OS/application. For example, WINDOWS(SM) obtains the context ID from the first fragment, but SAMBA contrarily uses the last fragment. The present inventor has performed tests and observed that the fragment to select as providing the source of the context ID varies according to the recipient OS/application. Hence, it can be important to select the context ID from a correct one of the fragments so as to better emulate the target.

The context ID is a known field in the DCE/RPC request header. However, there is no standard which dictates the fragment to use for obtaining the context ID for a reassembled DCE/RPC request.

The context ID identifies a collection of functions for remote procedure calls. In comparison to embodiment 4 (discussed below), the operation number (sometimes referred to as an opnum) identifies a function within that collection of functions. Together, the context ID and operation number identify the service and the function within that service that is being called. By using a context ID and/or operation number as used by the target, the IDS/IPS can determine whether that data in the remote procedure call will exploit a particular vulnerability within that service. If the IDS is not tracking the context ID that is used by the OS/application, then it will not put fragments together the same as the target OS/application (a so-called “DCE/RPC exploit”).

Consider a DCE/RPC exploit spanning a couple of fragments in a DCE/RPC request. The exploit is based on the function call within that service. If the IDS/IPS uses the wrong context ID, then the IDS/IPS is checking a non-existent service or wrong service to identify the exploit, which then could go unnoticed.

The IDS/IPS gathers together the request fragments. If the target is Windows, for example, then the first fragment is stored with its context ID as being the correct context ID. Later, when all of the fragments are reassembled and the request header is added (according to known techniques), the fragment which is the source of the context ID stored into the request header of the reassembled packet, is predetermined and selected based on the recipient OS/application since the fragment the context ID comes from varies depending on the target OS/application.

The third and/or fourth embodiments can be implemented with SMB processing or even TCP connection/non-SMB.

Referring now to FIG. 6, a diagram illustrating a prior art DCE/RPC processing will be discussed and described. This also illustrates an evasion example: DCE/RPC Request FRAG A 603 (context ID A, and op num X), DCE/RPC Request FRAG B 605 (context ID B, op num Y), and DCE/RPC Request FRAGC 607 (context ID B, op num Z, and an exploit for context ID B, op num Z). Each of these belongs to a single DCE/RPC request 601. The conventional IDS/IPS 613 interprets the fragments as belonging to a single DCE/RPC request 633 and hence does not evaluate the contents of the fragments the same as the target 615. The target OS/application in this application interprets operating system sees FRAGA 619, FRAG B 621, and FRAG C 623, together in a DCE/RPC request 625 with a DCE/RPC request header using context ID B and op num Z (from last fragment). The service and function call for context ID B and op num Z are vulnerable to the exploit which was not noticed by the IDS/IPS because the conventional IDS/IPS did not evaluate the context ID and op num from the same fragment as the target.

A third embodiment can improve the handling of DCE/RPC request fragments. A lookup table for DCE/RPC context ID (and in some embodiments, a separate lookup table for DCE/RPC op num reassembly) and can be included in the IDS/IPS or its preprocessor, for the combination of OS/application targeted by the DCE/RPC request. The concept of the look table is discussed above. The IDS/IPS or its preprocessor accordingly can flexibly and accurately evaluate DCE/RPC requests reconstructed from fragments.

Referring now to FIG. 7, a diagram illustrating target-based DCE/RPC processing according to a third and fourth embodiment will be discussed and described. In FIG. 7, the fragments FRAG A 703, FRAGB 705, FRAGC 707 in a single DCE/RPC request 701 are reassembled into a DCE/RPC request for evaluation by the IDS/IPS 701 just as it they assembled by the target 715. Furthermore, by referencing the DCE/RPC context ID reassembly table 714 to select which fragment to use as the source of the context ID, the IDS/IPS 713 can prepare DCE/RPC request headers with accurate context IDs, despite the DCE/RPC requests being transmitted to different kinds of OS/application combinations. Use of a DCE/RPC operation num reassembly table 712 similarly results in preparing the DCE/RPC request headers with accurate operation numbers.

Compare FIG. 6 to FIG. 7, with the same evasion example: DCE/RPC Request FRAG A 703 (context ID A, and op num X), DCE/RPC Request FRAG B 705 (context ID B, op num Y), and DCE/RPC Request FRAGC 707 (context ID 13, op num Z, and an exploit for context ID B, op num Z). Each of these belongs to a single DCE/RPC request 701. The IDS/IPS 713 references the DCE/RPC context ID reassembly table to select which of the fragments is the source of the context ID in the header for the reassembled DCE/RPC request. Because the header of the reassembled DCE/RPC request 735 which is evaluated by the IDS/IPS has the same context ID as the header 717 of the DCE/RPC request 725 at the target 715, the IDS/IPS can notice a DCE/RPC exploit.

Fourth Embodiment

The fourth embodiment further considers the effect of the operation number on the reassembly of DCE/RPC request fragments into DCE/RPC requests by the IDS/IPS prior to the evaluation of the DCE/RPC requests by the IDS/IPS. The fourth embodiment is similar to the third embodiment, except that the operation number is referenced instead of the context ID. Hence, most of the discussion of the third embodiment is not repeated here.

The context ID and operation number can be obtained from different fragments, depending on the kind of target. For example, for the context ID, all Windows versions use the first fragment as the source of the context ID, but for the operation number, only Windows Vista uses the first fragment as the source of the context ID.

Referring now to FIG. 8, a block diagram illustrating portions of an exemplary computer system 801 will be discussed and described. The computer system 801 may include one or more controllers 805, which can receive signals from a sensor 803 which senses communications from a network 835 in accordance with known techniques, where the communications are being sent to a target (not illustrated). The controller 805 can include a processor 807, a memory 813, an optional display 809, and/or an optional user input device such as a keyboard 811.

The processor 807 may comprise one or more microprocessors and/or one or more digital signal processors. The memory 813 may be coupled to the processor 807 and may comprise a read-only memory (ROM), a random-access memory (RAM), a programmable ROM (PROM), and/or an electrically erasable read-only memory (EEPROM). The memory 813 may include multiple memory locations for storing, among other things, an operating system, data and variables 815 for programs executed by the processor 807; computer programs for causing the processor to operate in connection with various functions such as receiving 817 a transmission, determining 819 a kind of application of the target of the transmission, determining 821 a kind of application of the target of the fragment/segment, determining 823 a kind of application of the target of a DCE/RPC request, including 825 data in the packet as named pipe data in certain predetermined situations, determining 827 whether the UID/RID is valid for the FID, and excluding the data from the named pipe data when the UID and/or TID is invalid for the FID, determining 829 whether the data includes an attack spanning plural packets, separating 831 fragments/segments by MID/PID, processing 833 the same SMB transaction command apart from fragments/segments with a different MID/PID, selecting 835 a predetermined one of the request fragments as the source of context ID and selecting a predetermined one of the request fragments as a source of the operating number, reassembling 837 the fragments in a reassembled request, and/or other processing; an SMB named pipe reassembly table 839, an SMB transaction reassembly table 841, a DCE/RPC context ID reassembly table 843, a DCE/RPC operation number reassembly table 845; a kind of application database 847; and a database 849 for other information used by the processor 807. The computer programs may be stored, for example, in ROM or PROM and may direct the processor 807 in controlling the operation of the computer system 801.

The processor 807 optionally may be programmed for receiving 817 a transmission. In the illustrated example, fragments or packets are detected by the sensor 803 connected to the computer system 801 and are supplied to the computer system 801 in accordance with known techniques.

The processor 807 may be programmed for determining 819 a kind of application associated with the target of the packet, determining 821 a kind of application of the target of the fragment/segment, and for determining 823 a kind of application associated with the target of the DCE/RPC request. In the typical situation, the packet or fragment identifies the target, for example as a destination IP address found in the packet header. A kind of application database 847 or table can be maintained for known destinations, which indicates the kind of application associated with a particular target. The kind of host database or table is intended to distinguish between applications and/or operating systems that reassemble segments differently for SMB named pipe processing, for SMB commands, and/or for DCE/RPC requests. Advantageously, a reassembly table or database can indicate whether and how fragments are assembled (such as the order of assembly and whether data in a packet with an invalid FID, TID and/or UID is included in the SMB named pipe data or not). In the illustrated example, the SMB named pipe reassembly table 839 includes two or more fragment reassembly patterns, which can be indexed, for example by the kind of application.

The data can be provided, for example, by parsing the received fragments or packets, by accumulating data from the fragments or packets in storage in the order, or by data from the fragments or packets being provided as input for another process (for example the intrusion detection/prevention unit).

The processor 807 may be programmed for including 825 data in the packet as named pipe data for certain predetermined applications. The data can be included, for example, by accumulating data from the fragments or packets in storage if the reassembly table indicates that it is added, or by data from the fragments or packets being provided as input for another process (for example the intrusion detection/prevention unit).

The processor 807 may be programmed for determining 827 whether the UID/RID is valid for the FID, and excluding the data from the named pipe data when the UID and/or TID is invalid for the FID. Examples are discussed herein.

The processor 807 may be programmed for determining 829 whether the data includes an attack spanning plural packets. Examples are discussed herein.

The processor 807 may be programmed for separating 831 fragments/segments by MID/PID. Examples are discussed herein

The processor 807 may be programmed for processing 833 the same SMB transaction command apart from fragments/segments with a different MID/PID. Examples are discussed herein.

The processor 807 may be programmed for selecting 835 a predetermined one of the request fragments as the source of context ID and selecting a predetermined one of the request fragments as a source of the operation number. Examples are discussed herein.

The processor 807 may be programmed for specifically reassembling 837 the fragments in a reassembled request, and inserting the context ID and operation number into the DCE/RPC header which is added to the reassembled request before it is evaluated by the IDS/IPS for an intrusion. The reassembling can be done by, for example, storing the data from the fragments, in the order, in a storage location, to recreate the transmission. The recreated transmission can be provided for further processing, for example, to the intrusion detection/prevention unit.

An optional intrusion detection/prevention unit (not illustrated) can be included in the processor 807 can be programmed in accordance with known techniques, to evaluate whether the packets or fragments (properly assembled to match the behavior of the target) suggest an attempted intrusion.

The processor 807 may be programmed for various reassembly tables 839, 841, 843, 845. The reassembly tables 839, 841, 843 can be provided for implementing the different reassembly patterns. One or more of the reassembly tables 839, 841, 843, 845 alternatively can be stored in a remote database and accessed as needed.

The processor 807 may be programmed for a kind of application database 847. The kind of application database 847 can be maintained for known destinations, to indicate the kind of application associated with a particular destination. Optionally, the kind of application database 847 can be maintained remotely, and relevant kind of application information can be downloaded as needed. Optionally, the kind of application can be indicated in a table rather than a database.

It should be understood that various logical groupings of functions are described herein. Different realizations may omit one or more of these logical groupings. Likewise, in various realizations, functions may be grouped differently, combined, or augmented. Furthermore, functions including those identified as optional can be omitted from various realizations. Similarly, the present description may describe or suggest a database or collection of data and information. One or more embodiments can provide that the database or collection of data and information can be distributed, combined, or augmented, or provided locally (as illustrated) and/or remotely (not illustrated).

FIG. 9 and FIG. 10 are included to summarize SMB fields (FIG. 9) and DEC/RPC fields (FIG. 10) that are referenced by one or more embodiments. The format of SMB commands and DCE/RPC requests are well understood in the art.

Referring now to FIG. 9, a block diagram illustrating portions of an SMB frame header 923 and an SMB command header 925 will be discussed and described. The SMB frame header 923 includes standard fields for a tree ID (TID) 907, a process ID (PID) 909, a user ID (ID) 911, and a multiplex ID (MID) 913. The SMB command header 925 follows the SMB frame header 923. If a command field 903 in the SMB frame header requires a FID, the FID 919 is included as a field in the SMB command header 925. The FID 919 is in the SMB command header 925 (for an SMB command, such as write next, or transact, and other types of SMB write command). Other fields 903, 915, 919, 921 typically are included in the SMB frame header 923 and SMB command header 925.

Referring now to FIG. 10, a block diagram illustrating portions of a DCE/RPC request header 1009 will be discussed and described. The DCE/RPC request header 1009 includes standard fields for context ID 1003 and operation number 1005. Other fields 1001, 1007 are typically included in the DCE/RPC request header 1009.

FIG. 11, FIG. 12 and FIG. 13 are flow charts of procedures for analyzing SMB transmissions or DCE/RPC requests. FIG. 11 illustrates a procedure for checking for valid packets in an SMB named pipe using FID/UID/TID, FIG. 12 illustrates a process for checking for valid packets in an SMB named pipe using MID/PID, and FIG. 13 is an illustration of reassembling DCE/RPC request fragments while sensitive to a context ID and/or operation number. These procedures can advantageously be implemented on, for example, a processor of a controller, described in connection with FIG. 8 or other apparatus appropriately arranged. Although these are illustrated as separate procedures, it will be appreciated that the procedures of FIG. 11, FIG. 12 and FIG. 13 can be combined. FIG. 11, FIG. 12 and FIG. 13 are discussed in more detail below.

Referring now to FIG. 11, a flow chart illustrating a process 1101 to check for valid packets in an SMB named pipe according to the first embodiment will be discussed and described. In overview, the process 1101 includes receiving 1103 a packet in a transmission, determining 1105 a kind of application of the target of the packet, judging 1107 whether the FID is valid for the segments/fragments in the SMB named pipe, judging 1109 whether the FID is valid for the kind of application of the target of the packet, judging 1111 whether the kind of application of the target checks the FID, judging 1113 whether the UID/TID is valid for the FID, excluding 1115 data within the packet from the SMB named pipe data in the SMB named pipe, and including 1117 data from the packet as part of the SMB named pipe data in the SMB named pipe. These are described below, however, details that have previously been described are omitted.

The process 1101 can receive 1103 a packet in a transmission. The packet is received at the IDS/IPS. Because the packet is being evaluated by the IDS/IPS, the IDS/IPS will attempt to evaluate the packet as it will be interpreted by the target. Therefore, the process 1101 can determine 1105 a kind of application of the target of the packet. For example, the IP address of the target can be used to determine the kind of application/OS combination which is used on the target using known techniques.

So that the IDS/IPS will accurately simulate how the application/OS interprets data in the packets, data in the packets is included as part of the SMB named pipe data which the IDS/IPS inspects only if (A) the FID in the SMB command header of the packet is valid for both the segments/fragments in the SMB named pipe and for the determined kind of application of the target of the packet; or if (B) the kid of application of the target of the packet does not check the FID. Thus, the process 1101 can judge 1107 whether the FID is valid for the segments/fragments in the SMB named pipe, and can judge 1109 whether the FID is valid for the kind of application of the target of the packet. Also, the process 1101 can judge 1111 whether the kind of application of the target checks the FID. Because the data is included in the SMB named pipe data only when the FID is valid for the particular kind of application of the target, or when the target is of the kind that does not check the FID, the SMB named pipe data inspected by the IDS/IPS more accurately simulates the SMB named pipe data at the target. Effectively, the process can exclude 1115 data from the packet as part of the SMB named pipe data and can include 1117 data from the packet as part of the SMB named pipe data which is inspected by the IDS/IPS.

Optionally, the process 1101 can judge 1113 whether the UID and/or TID is valid for the FID. In the event that the UID and/or the TID is not valid for the FID, the data from the packet can be excluded from the SMB named pipe date which is inspected by the IDS/IPS.

Referring now to FIG. 12, a flow chart illustrating a process 1201 to check for valid packets in an SMB named pipe according to the second embodiment will be discussed and described. In overview, the process includes receiving 1203 a fragment/segment in a transmission in one SMB named pipe, determining 1205 a kind of the application of the target of the fragment/segment, judging 1207 whether the kind of application of the target separates fragments/segments based on the MID, separating 1209 fragments/segments with the same MID as part of the same SMB transaction command from fragments/segments with a different MID all in the same SMB named pipe, judging 1211 whether the kind of application of the target separates based on PID, further separating 1213 fragments/segments with the same MID and same PID as part of the same SMB transaction command from fragments/segments with a different MID or different PID all in the same SMB named pipe, processing 1215 the same SMB transaction command as being a SMB transaction command separate from those with a different MID or PID, and processing 1217 the fragments/segments as part of the SMB transaction. Each of these is described below, however, details that have previously been described are omitted.

The process 1201 can receive 1203 a fragment/segment in a transmission in one SMB named pipe. This has been described previously in sufficient detail.

The process 1201 can determine 1205 a kind of the application of the target of the fragment/segment using any known process, as previously described.

The process 1201 can judge 1207 whether the kind of application of the target separates fragments/segments based on the MID, such as by referring to a reassembly table. For example, the reassembly table can be indexed by the kind of application and can indicate whether to separate fragments based on MID. Equivalents can also be provided. The process 1201 can separate 1209 fragments/segments with the same MID as part of the same SMB transaction command from fragments/segments with a different MID all in the same SMB named pipe. In this case, the fragments/segments which are in the same SMB transaction have the same MID.

The process 1201 can judge 1211 whether the kind of application of the target separates based on PID, for example by referring to a reassembly table which indicates whether to separate fragments based on PID. The process 1201 further can separate 1213 fragments/segments with the same MID and same PID as part of the same SMB transaction command from fragments/segments with a different MID or different PID all in the same SMB named pipe. In this case, the fragments/segments which are in the same SMB transaction have the same MID and PID.

The process 1201 then can process 1215 the same SMB transaction command with the same MID (and perhaps same PID as discussed above) as being a separate SMB transaction, instead of with the different MID or PID, where the fragments/segments are all in the same SMB named pipe.

If the kind of application of the target does not separate based on MID, the process 1201 instead can process 1217 the fragments/segments as part of the SMB transaction.

Referring now to FIG. 13, a flow chart illustrating a process 1301 to reassemble DCE/RPC request fragments according to the third and fourth embodiments will be discussed and described. In overview, the process includes receiving 1303 fragments belonging to a single DCE/RPC request, determining 1305 a kind of application of the target of the DCE/RPC request, selecting 1307 a predetermined request fragment as a source of the context ID, selecting 1309 a predetermined request fragment as a source of the operation num, reassembling 1311 the DCE/RPC request, inserting 1313 the context ID and the operation number from the selected request fragment(s) into the DCE/RPC header of the reassembled requests, and evaluating 1315 the reassembled SMB request for intrusion. These are described below, however, details that have previously been described are omitted.

The process 1301 can receive 1303 fragments belonging to a single DCE/RPC request. Also, the process 1301 can determine 1305 a kind of application of the target of the DCE/RPC request. These have been previously described in detail.

The process 1301 can select 1307 a predetermined request fragment as a source of the context ID. The predetermined request fragment is associated with the kind of the application of the target. Thereby, different kinds of applications can indicate different request fragments. The request fragment could be, e.g., the first (or last) request fragment in order in the DCE/RPC request, the first (or last) request fragment in a DCE/RPC request to be received, or some intermediate request fragment.

The process 1301 can select 1309 a predetermined request fragment as a source of the operation number. The request fragment which is the source of the operation number may be different from the request fragment which is the source of the context ID.

The process 1301 can reassemble 1311 the DCE/RPC request, in accordance with known techniques, and can prepare a DCE/RPC header for the reassembled request. However, in comparison to conventional techniques, the process 1301 can insert 1313 the context ID and the operation number from the selected request fragment(s) into the DCE/RPC header of the reassembled requests.

Then, the process 1301 can evaluate 1315 the reassembled SMB request for intrusion in accordance with available IDS/IPS techniques.

Moreover, embodiments include a computer system configured with the foregoing computer-readable medium and/or method(s); and/or a communication network comprising at least one computer system configured with the foregoing computer-readable medium and/or method(s).

It should be noted that the communication networks of interest include those that transmit information in packets in accordance with SMB or DCE/RPC protocols, where the packets optionally can be formed into SMB segments/fragments or DCE/RPC request fragments, for example, those known as packet switching networks that transmit data, where data can be divided into packets before transmission, the packets are transmitted, and the packets are routed over network infrastructure devices, which are sent to a destination where the segments/fragments or packets can be reassembled into the packets. Such networks include, by way of example, the Internet, intranets, local area networks (LAN), wireless LANs (WLAN), wide area networks (WAN), and others. Protocols supporting communication networks that utilize packets include one or more of various networking protocols having any link layers that support the TCP transport layer, or any application that rides over the transport layer, and other wireless application protocols or wireline application protocols and/or other protocol structures, and variants and evolutions thereof. Such networks can provide wireless communications capability and/or utilize wireline connections such as cable and/or a connector, or similar.

SMB protocols include those known as SMB, SMB1, SMB2, Samba, Samba TNG, Linux SMB, CIFS, CIFS Client for Solaris, FreeBSD SMB, smbfs, Vision FS, JLAN, RTSMB, and variations and evolutions thereof. Typically, SMB protocol is operated between an SMB client and SMB server as source and destination, with the IDS/IPS being neither. SMB mainly provides access to file, printers, ports, and miscellaneous communications between the SMB client and SMB server.

DCE/RPC refers to a remote procedure call that supports access across multiple computers, as if it were all accessing on the same computer, as specified by the Open Group as DCE RPC 1.1, DCE RPC 1.2.2, DCE/RPC from Samba TNG, FreeDCE, PC/DCE, MSRPC, and variations and evolutions thereof.

Furthermore, the designation “intrusion detection/prevention system” (and IDS/IPS) is used herein to denote a device or software that passively or actively analyzes network traffic for intrusion. Examples of such devices or software are sometimes referred to as “intrusion detection system” (IDS), “intrusion prevention system” (IPS), “network intrusion detection system” (NIDS), “network intrusion protection system” (NIPS”), and the like, and variants or evolutions thereof. An intrusion detection/prevention system may be host-based, or may monitor traffic to a target system using, for example, sensors, anywhere between the target system and the intruder, typically after a final router or firewall. The designation “intrusion detection/prevention” is used herein to indicate the analysis of network traffic with respect to intrusion, whether the analysis is used passively (commonly referred to as “intrusion detection”) or actively (commonly referred to as “intrusion prevention”). Likewise, the designation “detect/prevent” is utilized to indicate either passive or active handling of intrusion, which may occur for example in an IDS, an IPS, or other software or device which incorporates an IDS or IPS function.

This disclosure is intended to explain how to fashion and use various embodiments in accordance with the invention rather than to limit the true, intended, and fair scope and spirit thereof. The invention is defined solely by the appended claims, as they may be amended during the pendency of this application for patent, and all equivalents thereof. The foregoing description is not intended to be exhaustive or to limit the invention to the precise form disclosed. Modifications or variations are possible in light of the above teachings. The embodiments) was chosen and described to provide the best illustration of the principles of the invention and its practical application, and to enable one of ordinary skill in the art to utilize the invention in various embodiments and with various modifications as are suited to the particular use contemplated. All such modifications and variations are within the scope of the invention as determined by the appended claims, as may be amended during the pendency of this application for patent, and all equivalents thereof, when interpreted in accordance with the breadth to which they are fairly, legally, and equitably entitled. 

1. A method performed in a processor of an intrusion detection/prevention system (IDS/IPS), for checking for valid packets in a server message block (SMB) named pipe in a communication network, comprising: receiving, in a processor configured as an IDS/IPS, a packet in a transmission and determining a kind of application of a target of the packet in response to receiving the packet; including, in the IDS/IPS, the data in the packet as part of the SMB named pipe data inspected by the IDS/IPS as part of the SMB named pipe on only one of a condition that: (a) a file ID (FID) in an SMB command header of the packet is valid (i) for segments/fragments in the SMB named pipe and (ii) for the determined kind of application of the target of the packet, as indicated by a reassembly table, and (b) the determined kind of application of the target of the packet does not check the FID, as indicated by the reassembly table.
 2. The method as in claim 1, wherein the reassembly table indicates whether and how each of the different kinds of applications check the FID in the SMB command header of the packet.
 3. The method as in claim 1, further comprising determining, in the IDS/IPS, whether a user identifier (UID) in an SMB frame header of the packet is valid for the FID in the segments/fragments in the SMB named pipe, for the determined kind of application of the target, and including the data in the packet as part of the SMB named pipe data only when the UID is valid for the FID.
 4. The method as in claim 1, further comprising determining, in the IDS/IPS, whether a tree identifier (TID) in an SMB frame header of the packet is valid for the FID in the segments/fragments in the SMB named pipe, for the determined kind of application of the target, and including the data in the packet as part of the SMB named pipe data only when the TID is valid for the FID.
 5. The method as in claim 1, further comprising determining, in the IDS/IPS, whether a TID and a UID in an SMB frame header of the packet are both valid for the FID in the segments/fragments in the SMB named pipe, for the determined kind of application of the target, and including the data in the packet as part of the SMB named pipe data only when both the TID and the UID are valid for the FID.
 6. The method as in claim 1, further comprising inspecting, in the IDS/IPS, the data included as part of the SMB named pipe data, to determine whether the data includes an attack spanning plural packets.
 7. A method performed in a processor of an intrusion detection/prevention system (IDS/IPS), for checking for valid packets in a server message block (SMB) named pipe in a communication network, comprising: receiving, in a processor configured as an IDS/IPS, a fragment/segment, and determining a kind of application of a target of the fragment/segment in response to receiving the fragment/segment; separating, in the IDS/IPS, fragments/segments with a same multiplex ID (MID) as part of a same SMB transaction command from fragments/segments with a different MID, the MID being in the SMB frame header, all for fragments/segments in the same SMB named pipe, when a reassembly table indicates that the kind of application of the target separates based on MID; and processing, in the IDS/IPS, the same SMB transaction command with the same MID as being in a separate SMB transaction command instead of with the fragments/segments with the different MID when the kind of application of the target separates based on MID.
 8. The method as in claim 7, wherein the reassembly table indicates whether each of the different kinds of applications check the MID in the SMB frame header.
 9. The method as in claim 7, wherein the separating further comprises separating, in the IDS/IPS, fragments/segments with the same MID and a same caller process ID (PID) in the SMB frame header as part of the same SMB transaction command, from fragments/segments with the different MID or a different PID, all for fragments/segments in the same SMB named pipe, when the kind of application of the target also separates based on PID.
 10. The method as in claim 9, wherein the reassembly table indicates whether each of the different kinds of applications check the MID and the PID in the SMB frame header.
 11. The method as in claim 7, wherein the SMB transaction command comprises a main transaction and a secondary transaction.
 12. The method as in claim 7, further comprising inspecting, in the IDS/IPS, the data included as part of the same SMB transaction command, to determine whether the data includes an attack spanning plural fragments/segments in the same SMB transaction command.
 13. A method performed in a processor of an intrusion detection/prevention system (IDS/IPS), for reassembling distributed computing environment/remote procedure call (DCE/RPC) request fragments, comprising: receiving, in a processor configured as an IDS/IPS, plural request fragments belonging to a single DCE/RPC request; determining, in the IDS/IPS, the kind of application of a target of the DCE/RPC request; selecting, in the IDS/IPS, one of the request fragments as a source of a context ID depending on the target kind of application as indicated in a reassembly table; reassembling, in the IDS/IPS, the plural request fragments into a reassembled request; and inserting, in the IDS/IPS, the context ID from the selected request fragment into the context ID of a DCE/RPC header of the reassembled request.
 14. The method as in claim 13, wherein the reassembly table indicates which of the request fragments is selected as the source of the context ID for each of the different kinds of applications.
 15. The method of claim 13, further comprising: selecting, in the IDS/IPS, a different one of the request fragments as a source of an operation number depending on the target kind of application; and inserting, in the IDS/IPS, the operation number from a DCE/RPC header of the selected different one of the request fragments into the operation number of the DCE/RPC header of the reassembled request.
 16. The method as in claim 15, wherein the reassembly table indicates which of the request fragments is selected as the source of the context ID, and which different one of the request fragments is selected as the source of the operation number, for each of the different kinds of applications.
 17. The method of claim 13, further comprising: selecting, in the IDS/IPS, the one of the request fragments as a source of an operation number; and inserting, in the IDS/IPS, the operation number from the DCE/RPC header of the selected request fragment into the operation number of a DCE/RPC header of the reassembled request.
 18. The method as in claim 17, wherein the reassembly table indicates which of the request fragments is selected as the source of both the operation number and the context ID for each of the different kinds of applications.
 19. A method performed in a processor of an intrusion detection/prevention system (IDS/IPS), for reassembling request fragments, comprising: receiving, in a processor configured as an IDS/IPS, plural request fragments belonging to a single request; determining, in the IDS/IPS, the kind of application of a target of the request; selecting, in the IDS/IPS, one of the request fragments as a source of an operation number as indicated in a reassembly table depending on the target kind of application; reassembling, in the IDS/IPS, the plural request fragments into a reassembled request; and inserting, in the IDS/IPS, the operation number from a distributed computing environment/remote procedure call (DCE/RPC) header of the selected request fragment into the operation number of a DCE/RPC header of the reassembled request.
 20. The method as in claim 19, wherein the reassembly table indicates which of the request fragments is selected as the source of the operation number for each of the different kinds of applications.
 21. (canceled) 